package com.example.hospital_208.dao;

import com.example.hospital_208.po.Department;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface DepartmentDao {
    // 新增方法
    List<String> findMainDepartmentNames();
    List<String> findSubDepartmentNames(Integer parentId);

    // 原有方法
    List<Department> findAllDepartments();
    Department findDepartmentById(Integer department_id);
    int insertDepartment(Department department);
    int updateDepartment(Department department);
    int deleteDepartmentById(Integer department_id);
    // DepartmentDao.java
    Integer findDepartmentIdByName(String departmentName);
}